package com.eastfair.questionnaire.dto;

import com.eastfair.core.excel.bean.ExcelFiledAnnotation;
import com.eastfair.questionnaire.enums.QuestionTypeEnum;
import lombok.Data;

import java.util.List;
import java.util.stream.Collectors;
import java.util.stream.Stream;

/**
 * @ClassName QuestionnaireExcel
 * @Description excel导入问卷
 * @Author yuwx
 * @Date 2021/9/4 15:25
 * @Version 1.0
 **/
@Data
public class QuestionnaireExcelDTO {
    public static final List<String> HEADER = Stream.of("问卷名",	"题号",	"题目中文名称",	"题目中文别名",	"题目英文名称",	"题目英文别名",
            "题型(填空:TEXT，单选:RADIO，多选:CHECK_BOX)",	"是否必填(1:必填, 0:非必填)",	"最多选择数量",	"至少选择数量",	"一级答案中文名",	"一级答案中文别名",
            "一级答案英文名",	"一级答案英文别名",	"二级答案中文名",	"二级答案中文别名",	"二级答案英文名",	"二级答案英文别名",	"答案提示语",	"答案是否可填空(1:填空, 0:非填空)",	"跳题(下一题题号)")
            .collect(Collectors.toList());
    @ExcelFiledAnnotation(0)
    private String questionnaireName;
    @ExcelFiledAnnotation(1)
    private Integer questionSequence;
    @ExcelFiledAnnotation(2)
    private String questionName;
    @ExcelFiledAnnotation(3)
    private String questionAliasName;
    @ExcelFiledAnnotation(4)
    private String questionEnName;
    @ExcelFiledAnnotation(5)
    private String questionEnAliasName;
    @ExcelFiledAnnotation(6)
    private QuestionTypeEnum questionType;
    @ExcelFiledAnnotation(7)
    private Boolean isRequire;
    @ExcelFiledAnnotation(8)
    private Integer selectUpper;
    @ExcelFiledAnnotation(9)
    private Integer selectLower;
    @ExcelFiledAnnotation(10)
    private String answerName;
    @ExcelFiledAnnotation(11)
    private String answerAliasName;
    @ExcelFiledAnnotation(12)
    private String answerEnName;
    @ExcelFiledAnnotation(13)
    private String answerEnAliasName;
    @ExcelFiledAnnotation(14)
    private String subAnswerName;
    @ExcelFiledAnnotation(15)
    private String subAnswerAliasName;
    @ExcelFiledAnnotation(16)
    private String subAnswerEnName;
    @ExcelFiledAnnotation(17)
    private String subAnswerEnAliasName;
    @ExcelFiledAnnotation(18)
    private String answerDefaultTip;
    @ExcelFiledAnnotation(19)
    private Boolean isAnswerInput;
    @ExcelFiledAnnotation(20)
    private Long nextQuestionSequence;
}
